package net.dopan.pigframe.demo.model.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import lombok.*;

import java.io.Serializable;

/**
 * @author wufeihong
 * 评论点赞表
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@TableName("comment_like" )
public class
CommentLike extends Model<CommentLike> {

    private static final long serialVersionUID = 1L;
    /**
     * 点赞ID
     */
    @TableId(value = "like_id", type = IdType.AUTO)
    private long likeId;
    /**
     * 评论ID
     */
    @TableField("comment_id" )
    private long commentId;
    @TableField("user_id" )
    private long userId;

    @Override
    protected Serializable pkVal() {
        return this.likeId;
    }
}
